package com.team7.sso.feign;


import com.team7.sso.entity.User;
import com.team7.sso.vo.CommonResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;

@FeignClient(value = "video-system")
public interface UserFeign {

    @GetMapping("/system/user/findUserByUserName/{username}")
    public User findUserByUserName(@PathVariable("username") String username);

    @GetMapping("/system/user/findUserPermissionById/{userId}")
    public List<String> findUserPermissionById(@PathVariable("userId") String userId);

    @GetMapping("/system/user/updateUserPassword/{oldPassword}/{newPassword}/{salt}")
    public CommonResult updateUserPassword(@PathVariable("oldPassword")String oldPassword, @PathVariable("newPassword")String newPassword, @PathVariable("salt")String salt);
}